#ifndef _FMAPDLG_H
#define _FMAPDLG_H

#include  "config.h"

class CFreqBandDlg : public CDialogImpl<CFreqBandDlg>, 
                 public CWinDataExchange<CFreqBandDlg>
{
	
public:
    enum { IDD = IDD_FREQBAND };
 
    BEGIN_MSG_MAP(CImageSizeDlg)
        MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
        MESSAGE_HANDLER(WM_CLOSE, OnClose)
		COMMAND_ID_HANDLER(IDOK, OnOK)
        COMMAND_ID_HANDLER(IDCANCEL, OnCancel)

		//REFLECT_NOTIFICATIONS ()
	END_MSG_MAP()
 
    LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
    {
        CenterWindow();
		//Config::g_configFile.read();
		RECT rect={0,0,100,100};
		names[0].Create(this->m_hWnd, rect, 0, WS_CHILD | WS_VISIBLE|WS_BORDER,WS_EX_CLIENTEDGE);
		names[0].ShowWindow(SW_SHOW);

		DoDataExchange(FALSE);
        return TRUE;    // let the system set the focus

    }


    LRESULT OnClose(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
    {
        EndDialog(IDCANCEL);
        return 0;
    }

	LRESULT OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
    {
        EndDialog(wID);
        return 0;
    }
	LRESULT OnOK(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
    {
		if(DoDataExchange(TRUE)==0)
		{
			MessageBox(_T("Invalid value."));
			return 0;
		}

		
		//Config::g_configFile.write();
        EndDialog(wID);
        return 0;
    }

	BEGIN_DDX_MAP(CFreqBandDlg)

		//DDX_CONTROL(IDC_COMBOCOLOR, cb_color);
    END_DDX_MAP()

protected:
	CEdit names[7];
	
public:

};
#endif